

***Import dataset***

import excel "/Users/[  ]/Vink_Schakel_Reichel_Chun_deGroot_2019_main.xlsx", sheet("Sheet1") firstrow

import delimited "/Users/[  ]/Vink_Schakel_Reichel_Chun_deGroot_2019_main.csv"

use "/Users/[  ]/Vink_Schakel_Reichel_Chun_deGroot_2019_main.dta"



**Create variables**

**Note that the Stata datasheets already contain the newly created variables**

gen log_remit_received = log(remit_received)
gen log_sppoptotl = log(sp_pop_totl)
gen log_nygdppcapcd = log(ny_gdp_pcap_cd)

gen electoral_democracy = .
replace electoral_democracy = 0 if v2x_regime==0
replace electoral_democracy = 0 if v2x_regime==1
replace electoral_democracy = 1 if v2x_regime==2
replace electoral_democracy = 1 if v2x_regime==3
**or use variable 'v2x_regime_dem' from the .xlsx or .csv files**

gen recent_period = 0
replace recent_period = 1 if year>=1988
sum recent_period




***DEFINE SURVIVAL MODEL***

stset start, failure(dualcit_binary2==1) id(country_x)



***TABLE 1***

**model 1**

stcox change_dual_cit_neighbours1_2 vfa_intro_last3y electoral_democracy recent_period independ_af_1960 if year>1960 & year<2018 

**model 2**
 
stcox change_dual_cit_neighbours1_2##vfa_intro_last3y electoral_democracy recent_period independ_af_1960 if year>1960 & year<2018 

**model 3**

stcox change_dual_cit_neighbours1_2 vfa_intro_last3y electoral_democracy recent_period independ_af_1960 if year>1960 & year<2018 & log_sppoptotl!=. &  log_nygdppcapcd !=. & log_remit_received!=.

**model 4**

stcox change_dual_cit_neighbours1_2 vfa_intro_last3y log_remit_received electoral_democracy recent_period independ_af_1960 log_nygdppcapcd log_sppoptotl if year>1960 & year<2018 





***FIGURE 3***

**Note that the dual citizenship probabilities are stored in the outfile with the specified name**

stcox change_dual_cit_neighbours1_2 recent_period vfa_intro_last3y electoral_democracy independ_af_1960 if year>1960 & year<2018
stcurve, survival at1(change_dual_cit_neighbours1_2=0) at2(change_dual_cit_neighbours1_2=0.35) outfile(survival_plot1)
stcurve, survival at1(vfa_intro_last3y=0)  at2(vfa_intro_last3y=0.2)  outfile(survival_plot2)




***TABLE 2***

**model 5**

stcox change_dual_cit_neighbours1_2 vfa_intro_last3y electoral_democracy recent_period independ_af_1960 if year>1960 & year<2018 & change_dual_cit_neighbours1_2!=. & vfa_intro_last3y!=. & electoral_democracy!=. & recent_period!=. & independ_af_1960!=. & change_dual_cit_regional_1_2!=. & mean_dual_cit_neighbours500km!=. & ch_dual_cit_non_nghb1_2!=. & vfa_intro_coming5y!=.

**model 6**

stcox change_dual_cit_regional_1_2 vfa_intro_last3y electoral_democracy recent_period independ_af_1960 if year>1960 & year<2018 & change_dual_cit_neighbours1_2!=. & vfa_intro_last3y!=. & electoral_democracy!=. & recent_period!=. & independ_af_1960!=. & change_dual_cit_regional_1_2!=. & mean_dual_cit_neighbours500km!=. & ch_dual_cit_non_nghb1_2!=. & vfa_intro_coming5y!=.

**model 7**

stcox mean_dual_cit_neighbours500km vfa_intro_last3y electoral_democracy recent_period independ_af_1960 if year>1960 & year<2018  & change_dual_cit_neighbours1_2!=. & vfa_intro_last3y!=. & electoral_democracy!=. & recent_period!=. & independ_af_1960!=. & change_dual_cit_regional_1_2!=. & mean_dual_cit_neighbours500km!=. & ch_dual_cit_non_nghb1_2!=. & vfa_intro_coming5y!=.

**model 8**

stcox ch_dual_cit_non_nghb1_2 vfa_intro_last3y electoral_democracy recent_period independ_af_1960 if year>1960 & year<2018  & change_dual_cit_neighbours1_2!=. & vfa_intro_last3y!=. & electoral_democracy!=. & recent_period!=. & independ_af_1960!=. & change_dual_cit_regional_1_2!=. & mean_dual_cit_neighbours500km!=. & ch_dual_cit_non_nghb1_2!=. & vfa_intro_coming5y!=.

**model 9*

stcox change_dual_cit_neighbours1_2 vfa_intro_coming5y electoral_democracy recent_period independ_af_1960 if year>1960 & year<2018  & change_dual_cit_neighbours1_2!=. & vfa_intro_last3y!=. & electoral_democracy!=. & recent_period!=. & independ_af_1960!=. & change_dual_cit_regional_1_2!=. & mean_dual_cit_neighbours500km!=. & ch_dual_cit_non_nghb1_2!=. & vfa_intro_coming5y!=.

**model 10**

**Note that for running model 10 one needs to open a different datasheet**
***see below***



***TABLE A2: DESCRIPTIVE STATISTICS***


**models 1-2**

sum dualcit_binary2 change_dual_cit_neighbours1_2 vfa_intro_last3y electoral_democracy recent_period independ_af_1960 if year>1960 & year<2018 & dualcit_binary2!=. & change_dual_cit_neighbours1_2!=. & vfa_intro_last3y!=. & electoral_democracy!=. & recent_period!=. & independ_af_1960!=.

**models 3-4**

sum dualcit_binary2 change_dual_cit_neighbours1_2 vfa_intro_last3y electoral_democracy recent_period independ_af_1960 log_remit_received log_sppoptotl log_nygdppcapcd if year>1960 & year<2018 & dualcit_binary2!=. & change_dual_cit_neighbours1_2!=. & vfa_intro_last3y!=. & electoral_democracy!=. & recent_period!=. & independ_af_1960!=. & log_remit_received!=. & log_sppoptotl!=. & log_nygdppcapcd!=.

**models 5-9**

sum dualcit_binary2 change_dual_cit_neighbours1_2 vfa_intro_last3y electoral_democracy recent_period independ_af_1960 mean_dual_cit_neighbours500km ch_dual_cit_non_nghb1_2 change_dual_cit_regional_1_2 vfa_intro_coming5y if year>1960 & year<2018 & dualcit_binary2!=. & change_dual_cit_neighbours1_2!=. & vfa_intro_last3y!=. & electoral_democracy!=. & recent_period!=. & independ_af_1960!=. & change_dual_cit_regional_1_2!=. & mean_dual_cit_neighbours500km!=. & ch_dual_cit_non_nghb1_2!=. & vfa_intro_coming5y!=.

**model 10**

**Note that for running model 10 one needs to open a different datasheet**
***see below***



***TABLE A3: ALTERNATIVE OPERATIONALIZATIONS***


**model 11**

stcox change_dual_cit_neighbours1_5 vfa_intro_last5y electoral_democracy recent_period independ_af_1960 if year>1960 & year<2018 & change_dual_cit_neighbours1_5!=. & change_dual_cit_regional_1_5 !=. & ch_dual_cit_non_nghb1_5!=. & vfa_intro_coming5y!=.

**model 12**

stcox change_dual_cit_regional_1_5 vfa_intro_last5y electoral_democracy recent_period independ_af_1960 if year>1960 & year<2018 & change_dual_cit_neighbours1_5!=. & change_dual_cit_regional_1_5 !=. & ch_dual_cit_non_nghb1_5!=. & vfa_intro_coming5y!=.



***TABLE 2 + TABLE A3: MODEL 10***


**Note that for running model 10 + descriptives one needs to open a different datasheet (excluding backsliding countries)**

import excel "/Users/[  ]/Vink_Schakel_Reichel_Chun_deGroot_2019_excl_backsliding_countries.xlsx", sheet("Sheet1") firstrow

stset start, failure(dualcit_binary2==1) id(country_x)

**descriptives model 10 (Table A2)**
sum dualcit_binary2 change_dual_cit_neighbours1_2 vfa_intro_last3y electoral_democracy recent_period independ_af_1960 if year>1960 & year<2018 & dualcit_binary2!=. & change_dual_cit_neighbours1_2!=. & vfa_intro_last3y!=. & electoral_democracy!=. & change_dual_cit_neighbours1_5!=. & mean_dual_cit_neighbours500km!=. & vfa_intro_last5y!=. & vfa_intro_coming3y!=. & vfa_intro_coming5y!=.

**model 10 (Table 2)
stcox change_dual_cit_neighbours1_2 vfa_intro_last3y electoral_democracy recent_period independ_af_1960 if year>1960 & year<2018 & dualcit_binary2!=. & change_dual_cit_neighbours1_2!=. & vfa_intro_last3y!=. & electoral_democracy!=. & change_dual_cit_neighbours1_5!=. & mean_dual_cit_neighbours500km!=. & vfa_intro_last5y!=. & vfa_intro_coming3y!=. & vfa_intro_coming5y!=.
